/**
 * Project Name:ttt
 * File Name:ClientService.java
 * Package Name:com.bgi
 * Date:2015-3-11下午03:01:13
 * Copyright (c) 2015, BGI_DX All Rights Reserved.
 *
 */

package com.bgi.uims.pub.auth;

import org.apache.cxf.jaxws.JaxWsProxyFactoryBean;

/**
 * ClassName:ClientService <br/>
 * Function: TODO ADD FUNCTION. <br/>
 * Reason: TODO ADD REASON. <br/>
 * Date: 2015-3-11 下午03:01:13 <br/>
 * 
 * @author fukun
 * @version
 * @since JDK 1.7
 * @see
 */
public class ClientService {
	public static LoginWebservice getClientService(String address) {
		JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean();
		factory.setServiceClass(LoginWebservice.class);
		factory.setAddress(address);
		LoginWebservice service = (LoginWebservice) factory.create();
		return service;
	}

	public static void main(String[] args) {

		System.out.println(getClientService("http://192.168.225.54:8080/loginService/services/loginService?wsdl").emailLogin("user", "pwd"));

	}
}
